﻿@model IEnumerable<b7.Models.Ad>

@{
    ViewBag.Title = "Index";
}

<h2>Index</h2>

<p>
    @Html.ActionLink("Create New", "Create")
</p>
<table>
    <tr>
        <th>
            AdName
        </th>
        <th>
            AdImage
        </th>
        <th>
            AdLink
        </th>
        <th>
            Level
        </th>
        <th>
            ShowId
        </th>
        <th>
            ShowPosition
        </th>
        <th>
            Description
        </th>
        <th></th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.AdName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.AdImage)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.AdLink)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Level)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.ShowId)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.ShowPosition)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Description)
        </td>
        <td>
            @Html.ActionLink("Edit", "Edit", new { id=item.AdId }) |
            @Html.ActionLink("Details", "Details", new { id=item.AdId }) |
            @Html.ActionLink("Delete", "Delete", new { id=item.AdId })
        </td>
    </tr>
}

</table>
